<template>
  <el-container style="height: 100%;" class="dealBaseHome fundBaseHome">
    <el-header class="app-header">
      <div class="titlebar">
        <div class="titlebar-title">
          <div class="title">
            <div class="tit">
              <el-button class="tipText" type="text">
                <p style="width:100%;"> {{ name }}</p>
              </el-button>
            </div>
            <div class="tab-change" style="flex: 1;justify-content: flex-end;">
              <Internationalization v-show="name === '国际化'" />
            </div>
            <div class="btns">
              <backTop />
            </div>
          </div>
        </div>
      </div>
    </el-header>
    <div class="page-component__scroll">
      <fullView
        ref="fullView"
        :bus-id="busId"
        bus-type=""
        :child-left-menu="menuList"
        :bus-name="name"
        :default-active="activeIndex"
      />
    </div>
  </el-container>
</template>

<script>
  import { childMenuList	} from '@/api/system/menu'
  import { getInternalBase } from '@/api/fund/internal/internalBase'
  import fullView from '@/components/fullView'
  export default {
    components: {
      fullView
    },
    data() {
      return {
        loading: false,
        busId: this.$route.query.id,
        name: undefined,
        menuList: [],
        activeIndex: '',
        interFullName: undefined
      }
    },
    created() {
      this.init()
      this.busId = this.$route.query.id
    },
    mounted() {
      this.listComponent()
    },
    methods: {
      init() {
        getInternalBase(this.$route.query.id).then(response => {
          this.name = document.title = response.data.interFullName
          this.listLoad()
        })
      },
      listLoad() {
        // 菜单列表
        childMenuList('internal_menu').then(response => {
          this.menuList = response.rows
          this.activeIndex = this.menuList[0].id
        })
      }
    }
  }
</script>

<style scoped>

</style>
